<template>
  <view>
    <view class="c-pagination" v-if="props.loading">
      {{ props.loadingText }}
    </view>
    <c-empty
      v-else-if="props.isEmpty"
      :text="props.emptyText"
      :src="props.emptySrc"
    />
    <view class="c-pagination" v-else-if="props.finish">
      {{ props.finishText }}
    </view>
    <view class="c-pagination" v-else>{{ props.stayText }}</view>
  </view>
</template>
<script setup>
import { View } from '@tarojs/components';
import CEmpty from './CEmpty.vue';


const props = defineProps({
  loading: Boolean,
  isEmpty: Boolean,
  finish: Boolean,
  loadingText: {
    type: String,
    default: '拼命加载中...'
  },
  stayText: {
    type: String,
    default: '上拉加载更多'
  },
  finishText: {
    type: String,
    default: '我是有底线的'
  },
  emptyText: String,
  emptySrc: String
});

</script>
<style lang="scss">
.c-pagination{
    line-height: 80px;
    height: 80px;
    text-align: center;
    font-size: 24px;
    color: var(--color-gray);
}
</style>
